{% extends "layouts/application.html" %}
{% block content %}

<script>
function pageselectCallback(page_id, jq){
	//alert(page_id)
	window.location.href="?page="+(page_id+1);
}
$(document).ready(function(){
	// Create pagination element
    $("#Pagination").pagination({{objects.paginator.count}}, {
		num_edge_entries: 2,
		num_display_entries: 8,
		current_page:({{objects.number}}-1),
        callback: pageselectCallback
    });
});
</script>
<div align="center">
  <div class="boxright">
    <div class="bltop2">
      <div align="left">
        <strong>&nbsp;&nbsp;&nbsp;当前位置：&nbsp;&nbsp;
        <a href="#">回收站</a>
        </strong>
      </div>
    </div>
    <div>
        <form id="trash" action="" method="post">
          <TABLE class="tatop7px" cellSpacing=0 cellPadding=4 width="100%" border=0>
            <TBODY>
              <TR>
                <TD class="rtdw" width="4%">
                <INPUT id="chkAll" onclick="title_check('chkAll', 'chkID[]')"  type="checkbox" value="checkbox"></TD>
                <TD class="rep_li_c" width="40%"><STRONG>文件名</STRONG></TD>
                <TD class="rep_li_c" width="10%"><STRONG>上传人</STRONG></TD>
                <TD class="rep_li_c" width="10%"><STRONG>大小</STRONG></TD>
                <TD class="rep_li_c" width="20%"><STRONG>创建日期</STRONG></TD>
                <TD class="rep_li_c" width="15%"><STRONG>删除人</STRONG></TD>

              </TR>
              {% for file in objects.object_list%}
                <TR id="tr_{{file.id}}" style="TEXT-DECORATION: none" onMouseOver="this.style.backgroundColor='#EFF8FF'" onmouseout="this.style.backgroundColor=''">
                  <TD class="rtdw2">
                  <INPUT onclick="return rows_check('chkAll', 'chkID[]')" type=checkbox value="{{file.id}}" name="chkID[]"></TD>
                  <TD class="rep_li_td_bt" ALIGN="left">{{file.name}}</TD>
                  <TD class="rep_li_td_bt">{{file.user}}</TD>
                  <TD class="rep_li_td_bt">{{file.size|filesizeformat}}</TD>
                  <TD class="rep_li_td_bt">{{file.datetime|date:"Y年n月j日h点i分"}}</TD>
                  <TD class="rep_li_td_bt">{{file.del_user}}</TD>
                </TR>
              {% endfor %}
            </TBODY>
          </TABLE>

          <TABLE cellSpacing=0 cellPadding=4 width="100%" border=0>
            <TBODY>
              <TR vAlign="top">
              <TR vAlign="top" ALIGN="left">
                <TD>
                  <INPUT onclick="return check_select('chkID[]','trash','/{%site_root%}/manage/trash_revert/')"
                         name="button" class="bt1" id="recovery"  type="submit" value="还原">
                  <INPUT onclick="return check_select('chkID[]','trash','/{%site_root%}/manage/trash_del/0')"
                         name="button" class="button" id="destroy" type="submit" value="彻底删除">
                </TD>
                <td><div id="Pagination" class="pagination"></td>
              </TR>
            </TBODY>
          </TABLE>
        </form>
     </div>
  </div>
</div>
{% endblock %}
